package com.ctg.payroll2.dao.social;

import java.sql.SQLException;
import java.util.List;

import com.ctg.payroll2.bean.filter.social.CsEmplsocialFilter;
import com.ctg.payroll2.bean.filter.social.PbEmployeeFilter;
import com.ctg.payroll2.bean.po.social.CsEmplsocial;
import com.ctg.platform.util.Page;

/**
 * 雇员社保档案Dao
 * @author 鲁力 2009-9-11 上午11:57:50
 *
 */
@SuppressWarnings("unchecked")
public interface EmployeeSocialRecordDao {
	/**
	 * 员工社保查询
	 * @param filter
	 * @return
	 */
	Page queryCsEmplsocial(CsEmplsocialFilter filter);
	/**
	 * 未社保员工查询
	 * @param filter
	 * @return
	 */
	Page queryCsEmployee(PbEmployeeFilter filter);
	/**
	 * 社保项目查询
	 * @param filter
	 * @return
	 */
	Page queryPbSocialItemsResult(CsEmplsocialFilter filter);
	/**
	 * 推荐模板查询
	 * @param filter
	 * @return
	 */
	Page queryRecomSocialTemplate(CsEmplsocialFilter filter);
	/**
	 * 推荐模板细项查询
	 * @param filter
	 * @return
	 */
	List queryRecomSocialTemplateDetail(CsEmplsocialFilter filter);
	/**
	 * 客户模板翻页查询
	 * @param filter
	 * @return
	 */
	Page queryCsSocialTemplate(CsEmplsocialFilter filter);
	/**
	 * 客户模板细项查询
	 * @param filter
	 * @return
	 */
	List queryCsSocialTemplateDetail(CsEmplsocialFilter filter);
	/**
	 * 员工社保档案详细信息翻页查询
	 * @param filter
	 * @return
	 */
	Page querycsEmplsocialDetails(CsEmplsocialFilter filter);
	/**
	 * 插入一条员工社保
	 * @param csEmplsocial
	 */
	void insertCsEmplsocial(CsEmplsocial csEmplsocial) throws SQLException;
	/**
	 * 假删除
	 * @param ids
	 */
	void fakeDeleteCsEmplsocial(String ids);
	/**
	 * 判断是否修改了比例或者基数
	 * @param emplsocial
	 * @return 0,没有修改比例和基数;1,修改了比例或者基数;-1,没有找到记录.
	 * @throws SQLException
	 */
	int checkisNeedToDemolish(CsEmplsocial emplsocial) throws SQLException;
	/**
	 * 拆分成两条
	 * @param emplsocial
	 * @throws SQLException
	 */
	void demolishCsEmpSocial(CsEmplsocial emplsocial) throws SQLException;
	/**
	 * 更新雇员社保
	 * @param emplsocial
	 * @return
	 * @throws SQLException
	 */
	int updateCsEmpSocial(CsEmplsocial emplsocial) throws SQLException;
	
	List getEmployeeBySocialItem(CsEmplsocialFilter filter) throws SQLException;
	CsEmplsocial retrieveEmployeeByFilter(CsEmplsocialFilter filter) throws SQLException;
	String checkEmpSSocialItemIsCaled(CsEmplsocial csEmplsocial) throws SQLException;
	int bjrjg(CsEmplsocial csEmplsocial) throws SQLException;
}
